package Demo2;

public class Test {
    public static void main(String[] args) {
        StringBuilder stringBuilder = new StringBuilder();
        stringBuilder.append(1234);
        stringBuilder.append("1234");

        String string = stringBuilder.toString();
        System.out.println(string);
    }
    public int[] separateDigits(int[] nums) {
        int[] newArray = new int[6000];
        int pos = 0;
        for(int i = 0;i<nums.length;i++){
            String str = String.valueOf(nums[i]);
            for(int k = 0;k<str.length();k++){
                newArray[pos++] = Integer.parseInt(String.valueOf(str.charAt(k)));
            }
        }
        return newArray;
    }
}
